const mongoose = require('mongoose')
const {Schema,model} = mongoose 
const blogSchema = new Schema({
  __v : {type: Number,select:false},
  uid : {type: String, required: true},
  blog :{type:[{
    title: {type: String, required: true},
    content: {type: String, required: false},
    img: {type: String, required: false},
    time: {type: String, required: false},
    isDelete: {type: Boolean,default:false, required: false},
  }]} // blog数组 元素分别为 title content img
},{timestamps:true})

module.exports = model("Blog",blogSchema) 